<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <link rel="stylesheet" href="http://www.petercorke.com/RVC/common/toolboxhelp.css">
    <title>M-File Help: ivar</title>
  </head>
  <body>
  <table border="0" cellspacing="0" width="100%">
    <tr class="subheader">
      <td class="headertitle">M-File Help: ivar</td>
      <td class="subheader-left"><a href="matlab:open ivar">View code for ivar</a></td>
    </tr>
  </table>
<h1>ivar</h1><p><span class="helptopic">Pixel window statistics</span></p><strong>out</strong> = <span style="color:red>ivar</span>(<strong>im</strong>, <strong>se</strong>, <strong>op</strong>) is an image where each output pixel is
the specified statistic over the pixel neighbourhood indicated by the
structuring element <strong>se</strong> which should have odd side lengths.  The elements
in the neighbourhood corresponding to non-zero elements in <strong>se</strong> are packed into
a vector on which the required statistic is computed.

The operation <strong>op</strong> is one of:

<table class="list">
  <tr><td style="white-space: nowrap;" class="col1"> 'var'</td> <td>variance</td></tr>
  <tr><td style="white-space: nowrap;" class="col1"> 'kurt'</td> <td>Kurtosis or peakiness of the distribution</td></tr>
  <tr><td style="white-space: nowrap;" class="col1"> 'skew'</td> <td>skew or asymmetry of the distribution</td></tr>
</table>
<strong>out</strong> = <span style="color:red>ivar</span>(<strong>im</strong>, <strong>se</strong>, <strong>op</strong>, <strong>edge</strong>) as above but performance at edge pixels
can be controlled.  The value of <strong>edge</strong> is:

<table class="list">
  <tr><td style="white-space: nowrap;" class="col1"> 'border'</td> <td>the border value is replicated (default)</td></tr>
  <tr><td style="white-space: nowrap;" class="col1"> 'none'</td> <td>pixels beyond the border are not included in the window</td></tr>
  <tr><td style="white-space: nowrap;" class="col1"> 'trim'</td> <td>output is not computed for pixels whose window crosses
the border, hence output image had reduced dimensions.</td></tr>
  <tr><td style="white-space: nowrap;" class="col1"> 'wrap'</td> <td>the image is assumed to wrap around</td></tr>
</table>
<h2>Notes</h2>
<ul>
  <li>Is a MEX file.</li>
</ul>
<h2>See also</h2>
<p>
<a href="matlab:doc irank">irank</a>, <a href="matlab:doc iwindow">iwindow</a></p>
<hr>

<table border="0" width="100%" cellpadding="0" cellspacing="0">
  <tr class="subheader" valign="top"><td>&nbsp;</td></tr></table>
<p class="copy">&copy; 1990-2011 Peter Corke.</p>
</body></html>